<!DOCTYPE html>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	    <meta name="format-detection" content="telephone=no">
	    <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
	    <link href="../../css/bootstrap.css" rel="stylesheet" />
	    <link href="../../css/cover.css" rel="stylesheet" />
	    <link href="../../css/font-awesome.min.css" rel="stylesheet" />
	    <title>荆州千网汇信息科技有限公司</title>
	    <script src="../../js/jquery-2.2.3.min.js"></script>
	    <script src="../../js/jquery.flexslider-min.js"></script>
	    <script src="../../js/rem.js"></script>
	    <script src="../../js/itnetcao.js"></script>
	    <link href="../../js/layui/css/layui.css" rel="stylesheet" />
	    <link href="../../js/donghua/animsition.min.css" rel="stylesheet" />
	    <script src="../../js/donghua/animsition.min.js"></script>
	    <link rel="stylesheet" href="../../css/minirefresh.css" />
	    <link rel="stylesheet" href="../../css/common.css" />
	    <script type="text/javascript" src="../../js/minirefresh.js"></script>
	    <script type="text/javascript" src="../../js/common.js"></script>
	    <script type="text/javascript" src="../../js/layer.js"></script>
		<style type="text/css">
		.img{
			
			
			width:200px;
			
			height:200px;
			
			border:20px solid green;
			
			border-left-color: red;
			
			border-right-color: blue;
			
			border-top-color: yellow;
			
			border-radius:50%;
			
			-webkit-animation:circle 2s infinite linear;/*匀速 循环*/
			
		}
			
		@-webkit-keyframes circle{
			
			0%{ transform:rotate(0deg); }
			
			100%{ transform:rotate(-360deg); }
			
		}
		@keyframes circle{
			
			0%{ transform:rotate(0deg); }
			
			100%{ transform:rotate(-360deg); }
			
		}
			
		</style>
	</head>
	<body>
		<div class="page_top01 relative">
            <h3 class="text-center">运行状态</h3>
            <a href="javascript:;" class="animsition-link" data-animsition-out-class="fade-out-right" data-animsition-out-duration="500" onclick="history.go(-1)">
                <img src="../../images/icon_left.png" class="img-responsive reture_img" /></a>
        </div>
        <div class='setImageWH' style='background:url(../../image/kuangjiyunxing.gif);background-size:cover;'>
        	<div style='position:fixed;display:inline-block;z-index:1000000000;top:0;left:0;' class='image_margin'>
				<div class='img'>
					
				</div>
			</div>
			
			<div style='color:red;position:fixed;display:inline-block;font-size:31px;top:80%;left:1%;z-index:1000000000;'>
				开采率:<span class='kuang_ji_kai_cai_shu_zi'></span>
			</div>
        </div>
        
		
		
	
<script type='text/javascript'>

$(".setImageWH").css({"width" : $(window).width(), "height" : $(window).height() - parseFloat($(".page_top01").css("height").replace("px", ""))});

$(".image_margin").css({"top" : "20%", "left" : ($(window).width() - 200) / 2})


var userId = jQuery.parseJSON(localStorage.getItem("miningmachine_user")).userId;
var dugId = localStorage.getItem("kuang_ji_id_desc");


var kuang_ji_kai_cai_lv = localStorage.getItem("kuang_ji_kai_cai_lv_" + dugId);
if(isNaN(kuang_ji_kai_cai_lv)) {
	kuang_ji_kai_cai_lv = "0.0000000000";
}
localStorage.setItem("kuang_ji_kai_cai_lv_" + dugId, kuang_ji_kai_cai_lv);
$(".kuang_ji_kai_cai_shu_zi").text(kuang_ji_kai_cai_lv);


var url = localStorage.getItem("url") + "/dug/controller/DugMoneyFindByIdAPP.do";
var data = "userId=" + userId + "&dugId=" + dugId;
itcao.itGetAjaxBigData(url, data).done(function(result) {
	var json = jQuery.parseJSON(result);
	if(json.state == true) {
		if(json.bean[0].dugType == 1) {
			weixin(json.bean[0].dugId, json.bean[0].dugMuchCurrency);
		}
		if(json.bean[0].dugType == 2) {
			chuji(json.bean[0].dugId, json.bean[0].dugMuchCurrency);
		}
		if(json.bean[0].dugType == 3) {
			zhongji(json.bean[0].dugId, json.bean[0].dugMuchCurrency);
		}
		if(json.bean[0].dugType == 4) {
			gaoji(json.bean[0].dugId, json.bean[0].dugMuchCurrency);
		}
	}
})
function weixin(id, kaicailv) {
	setInterval(function() {
		var suiji = ((Math.random() * (Math.random() * kaicailv) * 100) / 10000).toFixed(10);
		var count = localStorage.getItem("kuang_ji_kai_cai_lv_" + id);
		var sum = (parseFloat(suiji) + parseFloat(count)).toFixed(10);
		localStorage.setItem("kuang_ji_kai_cai_lv_" + id, sum);
		$(".kuang_ji_kai_cai_shu_zi").text(sum);
	}, 2000)
	
}
function chuji(id, kaicailv) {
	setInterval(function() {
		var suiji = ((Math.random() * (Math.random() * kaicailv) * 100) / 1000000).toFixed(10);
		var count = localStorage.getItem("kuang_ji_kai_cai_lv_" + id);
		var sum = (parseFloat(suiji) + parseFloat(count)).toFixed(10);
		localStorage.setItem("kuang_ji_kai_cai_lv_" + id, sum);
		$(".kuang_ji_kai_cai_shu_zi").text(sum);
	}, 2000)
}
function zhongji(id, kaicailv) {
	setInterval(function() {
		var suiji = ((Math.random() * (Math.random() * kaicailv) * 100) / 10000000).toFixed(10);
		var count = localStorage.getItem("kuang_ji_kai_cai_lv_" + id);
		var sum = (parseFloat(suiji) + parseFloat(count)).toFixed(10);
		localStorage.setItem("kuang_ji_kai_cai_lv_" + id, sum);
		$(".kuang_ji_kai_cai_shu_zi").text(sum);
	}, 2000)
}
function gaoji(id, kaicailv) {
	setInterval(function() {
		var suiji = ((Math.random() * (Math.random() * kaicailv) * 100) / 1000000000).toFixed(10);
		var count = localStorage.getItem("kuang_ji_kai_cai_lv_" + id);
		var sum = (parseFloat(suiji) + parseFloat(count)).toFixed(10);
		localStorage.setItem("kuang_ji_kai_cai_lv_" + id, sum);
		$(".kuang_ji_kai_cai_shu_zi").text(sum);
	}, 2000)
}
</script>
</body>
</html>
